Integrand size = 35, antiderivative size = 228 \[ \int \frac {A+B \tan (c+d x)}{\sqrt {\cot (c+d x)} \sqrt {a+b \tan (c+d x)}} \, dx=\frac {(i A-B) \arctan \left (\frac {\sqrt {i a-b} \sqrt {\tan (c+d x)}}{\sqrt {a+b \tan (c+d x)}}\right ) \sqrt {\cot (c+d x)} \sqrt {\tan (c+d x)}}{\sqrt {i a-b} d}+\frac {2 B \text {arctanh}\left (\frac {\sqrt {b} \sqrt {\tan (c+d x)}}{\sqrt {a+b \tan (c+d x)}}\right ) \sqrt {\cot (c+d x)} \sqrt {\tan (c+d x)}}{\sqrt {b} d}-\frac {(i A+B) \text {arctanh}\left (\frac {\sqrt {i a+b} \sqrt {\tan (c+d x)}}{\sqrt {a+b \tan (c+d x)}}\right ) \sqrt {\cot (c+d x)} \sqrt {\tan (c+d x)}}{\sqrt {i a+b} d} \]
[Out]
Time = 0.86 (sec) , antiderivative size = 228, normalized size of antiderivative = 1.00, number of steps used = 13, number of rules used = 10, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.286, Rules used = {4326, 3695, 3697, 3696, 95, 209, 212, 3715, 65, 223} \[ \int \frac {A+B \tan (c+d x)}{\sqrt {\cot (c+d x)} \sqrt {a+b \tan (c+d x)}} \, dx=\frac {(-B+i A) \sqrt {\tan (c+d x)} \sqrt {\cot (c+d x)} \arctan \left (\frac {\sqrt {-b+i a} \sqrt {\tan (c+d x)}}{\sqrt {a+b \tan (c+d x)}}\right )}{d \sqrt {-b+i a}}-\frac {(B+i A) \sqrt {\tan (c+d x)} \sqrt {\cot (c+d x)} \text {arctanh}\left (\frac {\sqrt {b+i a} \sqrt {\tan (c+d x)}}{\sqrt {a+b \tan (c+d x)}}\right )}{d \sqrt {b+i a}}+\frac {2 B \sqrt {\tan (c+d x)} \sqrt {\cot (c+d x)} \text {arctanh}\left (\frac {\sqrt {b} \sqrt {\tan (c+d x)}}{\sqrt {a+b \tan (c+d x)}}\right )}{\sqrt {b} d} \]
[In]
[Out]
Rule 65
Rule 95
Rule 209
Rule 212
Rule 223
Rule 3695
Rule 3696
Rule 3697
Rule 3715
Rule 4326
Rubi steps \begin{align*} \text {integral}& = \left (\sqrt {\cot (c+d x)} \sqrt {\tan (c+d x)}\right ) \int \frac {\sqrt {\tan (c+d x)} (A+B \tan (c+d x))}{\sqrt {a+b \tan (c+d x)}} \, dx \\ & = \left (\sqrt {\cot (c+d x)} \sqrt {\tan (c+d x)}\right ) \int \frac {-B+A \tan (c+d x)}{\sqrt {\tan (c+d x)} \sqrt {a+b \tan (c+d x)}} \, dx+\left (B \sqrt {\cot (c+d x)} \sqrt {\tan (c+d x)}\right ) \int \frac {1+\tan ^2(c+d x)}{\sqrt {\tan (c+d x)} \sqrt {a+b \tan (c+d x)}} \, dx \\ & = \frac {1}{2} \left ((-i A-B) \sqrt {\cot (c+d x)} \sqrt {\tan (c+d x)}\right ) \int \frac {1+i \tan (c+d x)}{\sqrt {\tan (c+d x)} \sqrt {a+b \tan (c+d x)}} \, dx+\frac {1}{2} \left ((i A-B) \sqrt {\cot (c+d x)} \sqrt {\tan (c+d x)}\right ) \int \frac {1-i \tan (c+d x)}{\sqrt {\tan (c+d x)} \sqrt {a+b \tan (c+d x)}} \, dx+\frac {\left (B \sqrt {\cot (c+d x)} \sqrt {\tan (c+d x)}\right ) \text {Subst}\left (\int \frac {1}{\sqrt {x} \sqrt {a+b x}} \, dx,x,\tan (c+d x)\right )}{d} \\ & = \frac {\left ((-i A-B) \sqrt {\cot (c+d x)} \sqrt {\tan (c+d x)}\right ) \text {Subst}\left (\int \frac {1}{(1-i x) \sqrt {x} \sqrt {a+b x}} \, dx,x,\tan (c+d x)\right )}{2 d}+\frac {\left ((i A-B) \sqrt {\cot (c+d x)} \sqrt {\tan (c+d x)}\right ) \text {Subst}\left (\int \frac {1}{(1+i x) \sqrt {x} \sqrt {a+b x}} \, dx,x,\tan (c+d x)\right )}{2 d}+\frac {\left (2 B \sqrt {\cot (c+d x)} \sqrt {\tan (c+d x)}\right ) \text {Subst}\left (\int \frac {1}{\sqrt {a+b x^2}} \, dx,x,\sqrt {\tan (c+d x)}\right )}{d} \\ & = \frac {\left ((-i A-B) \sqrt {\cot (c+d x)} \sqrt {\tan (c+d x)}\right ) \text {Subst}\left (\int \frac {1}{1-(i a+b) x^2} \, dx,x,\frac {\sqrt {\tan (c+d x)}}{\sqrt {a+b \tan (c+d x)}}\right )}{d}+\frac {\left ((i A-B) \sqrt {\cot (c+d x)} \sqrt {\tan (c+d x)}\right ) \text {Subst}\left (\int \frac {1}{1-(-i a+b) x^2} \, dx,x,\frac {\sqrt {\tan (c+d x)}}{\sqrt {a+b \tan (c+d x)}}\right )}{d}+\frac {\left (2 B \sqrt {\cot (c+d x)} \sqrt {\tan (c+d x)}\right ) \text {Subst}\left (\int \frac {1}{1-b x^2} \, dx,x,\frac {\sqrt {\tan (c+d x)}}{\sqrt {a+b \tan (c+d x)}}\right )}{d} \\ & = \frac {(i A-B) \arctan \left (\frac {\sqrt {i a-b} \sqrt {\tan (c+d x)}}{\sqrt {a+b \tan (c+d x)}}\right ) \sqrt {\cot (c+d x)} \sqrt {\tan (c+d x)}}{\sqrt {i a-b} d}+\frac {2 B \text {arctanh}\left (\frac {\sqrt {b} \sqrt {\tan (c+d x)}}{\sqrt {a+b \tan (c+d x)}}\right ) \sqrt {\cot (c+d x)} \sqrt {\tan (c+d x)}}{\sqrt {b} d}-\frac {(i A+B) \text {arctanh}\left (\frac {\sqrt {i a+b} \sqrt {\tan (c+d x)}}{\sqrt {a+b \tan (c+d x)}}\right ) \sqrt {\cot (c+d x)} \sqrt {\tan (c+d x)}}{\sqrt {i a+b} d} \\ \end{align*}
Time = 1.60 (sec) , antiderivative size = 225, normalized size of antiderivative = 0.99 \[ \int \frac {A+B \tan (c+d x)}{\sqrt {\cot (c+d x)} \sqrt {a+b \tan (c+d x)}} \, dx=\frac {\sqrt {\cot (c+d x)} \sqrt {\tan (c+d x)} \left (\sqrt [4]{-1} \left (-\frac {(A-i B) \arctan \left (\frac {\sqrt [4]{-1} \sqrt {-a+i b} \sqrt {\tan (c+d x)}}{\sqrt {a+b \tan (c+d x)}}\right )}{\sqrt {-a+i b}}+\frac {(A+i B) \arctan \left (\frac {\sqrt [4]{-1} \sqrt {a+i b} \sqrt {\tan (c+d x)}}{\sqrt {a+b \tan (c+d x)}}\right )}{\sqrt {a+i b}}\right )+\frac {2 \sqrt {a} B \text {arcsinh}\left (\frac {\sqrt {b} \sqrt {\tan (c+d x)}}{\sqrt {a}}\right ) \sqrt {1+\frac {b \tan (c+d x)}{a}}}{\sqrt {b} \sqrt {a+b \tan (c+d x)}}\right )}{d} \]
[In]
[Out]
result has leaf size over 500,000. Avoiding possible recursion issues.
Time = 0.98 (sec) , antiderivative size = 1887832, normalized size of antiderivative = 8279.96
\[\text {output too large to display}\]
[In]
[Out]
Leaf count of result is larger than twice the leaf count of optimal. 10230 vs. \(2 (180) = 360\).
Time = 4.35 (sec) , antiderivative size = 20493, normalized size of antiderivative = 89.88 \[ \int \frac {A+B \tan (c+d x)}{\sqrt {\cot (c+d x)} \sqrt {a+b \tan (c+d x)}} \, dx=\text {Too large to display} \]
[In]
[Out]
\[ \int \frac {A+B \tan (c+d x)}{\sqrt {\cot (c+d x)} \sqrt {a+b \tan (c+d x)}} \, dx=\int \frac {A + B \tan {\left (c + d x \right )}}{\sqrt {a + b \tan {\left (c + d x \right )}} \sqrt {\cot {\left (c + d x \right )}}}\, dx \]
[In]
[Out]
\[ \int \frac {A+B \tan (c+d x)}{\sqrt {\cot (c+d x)} \sqrt {a+b \tan (c+d x)}} \, dx=\int { \frac {B \tan \left (d x + c\right ) + A}{\sqrt {b \tan \left (d x + c\right ) + a} \sqrt {\cot \left (d x + c\right )}} \,d x } \]
[In]
[Out]
Exception generated. \[ \int \frac {A+B \tan (c+d x)}{\sqrt {\cot (c+d x)} \sqrt {a+b \tan (c+d x)}} \, dx=\text {Exception raised: TypeError} \]
[In]
[Out]
Timed out. \[ \int \frac {A+B \tan (c+d x)}{\sqrt {\cot (c+d x)} \sqrt {a+b \tan (c+d x)}} \, dx=\int \frac {A+B\,\mathrm {tan}\left (c+d\,x\right )}{\sqrt {\mathrm {cot}\left (c+d\,x\right )}\,\sqrt {a+b\,\mathrm {tan}\left (c+d\,x\right )}} \,d x \]
[In]
[Out]